import QtQuick 1.0

Item {
    property bool paused : true

    id: dlo
    width: map.width

    Image {
        id: dungeonWall
        fillMode: Image.Tile

        source: "res/img/wall_dungeon.png"
    }

    Interface {
        id: gameInterface
    }

    Map {
        source: "res/map/scenery03.tmx"
        id: map

        Player {
            id: player

            paused: dlo.paused

            startX: 30
            startY: 470

            z: 1

            level: "dungeonLevel"
        }

        Boss {
            id: boss

            paused: dlo.paused

            x: 600
            y: 450
        }

        Component.onCompleted: {
            // adjust background
            dungeonWall.width = width;
            dungeonWall.height = 800;
        }
    }

    function scroll(amount) {
        map.x -= amount;
        dungeonWall.x -= (amount / 2);
    }
}
